package com.burstly.lib.component;

import com.burstly.lib.network.ResponseObject;
import com.burstly.lib.network.beans.TrackClickResult;
import com.burstly.lib.util.LoggerExt;

public class BurstlyAdaptorController extends AdaptorController
{
  private ITrackClickResponseHandler mClickHandler;

  BurstlyAdaptorController(ControllerConfig paramControllerConfig)
  {
    super(paramControllerConfig);
  }

  protected void defaultPostClickCallback(TrackClickResult paramTrackClickResult)
  {
    if ((!this.mDestroyed) && (this.mClickHandler != null) && (this.mClickHandler != null))
      this.mClickHandler.handleResponse(paramTrackClickResult, this);
  }

  protected void getDataForComponent()
  {
    if (!this.mDestroyed)
    {
      ResponseObject localResponseObject = new ResponseObject();
      fillUpWithCurrentResponseData(localResponseObject);
      try
      {
        beginTransaction(localResponseObject);
        setAdaptorListener();
        if (isContinueProcessing(localResponseObject))
        {
          handleServerResponse(this);
          return;
        }
        LOG.logError(this.mTag, "Parsed response is null or parameters for this network are incorrect.", new Object[0]);
        this.mAdaptorListener.failedToLoad(this.mNetworkName, this.mIsInterstitial, "");
        return;
      }
      catch (Throwable localThrowable)
      {
        handleErrorFlow(this, localThrowable);
        return;
      }
    }
    LOG.logWarning(this.mTag, "Old Burstly View has been destroyed so safely skip rest of lifecycle.", new Object[0]);
  }

  public void showComponent()
  {
    super.showComponent();
    if ((this.mAdaptor instanceof IClickTracker))
      this.mClickHandler = ((IClickTracker)this.mAdaptor).getResponseHandler();
  }
}

/* Location:           E:\android\Toy Defense 2_dex2jar.jar
 * Qualified Name:     com.burstly.lib.component.BurstlyAdaptorController
 * JD-Core Version:    0.6.2
 */